package cn.xenosp.server.module.menu.entity;

import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.util.Date;
import java.util.List;

import lombok.Data;

/**
 * 菜单权限表
 * @TableName sys_menu
 */
@TableName(value ="sys_menu")
@Data
public class SysMenu implements Serializable {
    /**
     * 菜单ID
     */
    @TableId(value = "id")
    private String id;

    /**
     * 菜单名称
     */
    @TableField(value = "name")
    private String name;

    /**
     * 权限标识
     */
    @TableField(value = "permission")
    private String permission;

    /**
     * 菜单类型
     */
    @TableField(value = "type")
    private Integer type;

    /**
     * 显示顺序
     */
    @TableField(value = "sort")
    private Integer sort;

    /**
     * 父菜单ID
     */
    @TableField(value = "parent_id")
    private String parentId;

    /**
     * 路由地址
     */
    @TableField(value = "path")
    private String path;

    /**
     * 菜单图标
     */
    @TableField(value = "icon")
    private String icon;

    /**
     * 组件路径
     */
    @TableField(value = "component")
    private String component;

    /**
     * 组件名
     */
    @TableField(value = "component_name")
    private String componentName;

    /**
     * 菜单状态
     */
    @TableField(value = "status")
    private Integer status;

    /**
     * 是否可见
     */
    @TableField(value = "visible")
    private String visible;

    /**
     * 是否缓存
     */
    @TableField(value = "keep_alive")
    private Boolean keepAlive;

    /**
     * 是否总是显示
     */
    @TableField(value = "always_show")
    private Boolean alwaysShow;

    /**
     * 创建者
     */
    @TableField(value = "creator",fill= FieldFill.INSERT)
    private String creator;

    /**
     * 创建时间
     */
    @TableField(value = "create_time",fill= FieldFill.INSERT)
    private Date createTime;

    /**
     * 更新者
     */
    @TableField(value = "updater",fill= FieldFill.INSERT_UPDATE)
    private String updater;

    /**
     * 更新时间
     */
    @TableField(value = "update_time",fill= FieldFill.INSERT_UPDATE)
    private Date updateTime;

    /**
     * 是否删除
     */
    @TableField(value = "deleted")
    private Boolean deleted;

    @TableField(exist = false)
    private List<SysMenuVO> children;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;
}